<nz-modal
  [(nzVisible)]="isVisible"
  [nzTitle]="title"
  (nzOnCancel)="handleCancel()"
  (nzOnOk)="handleSubmit()"
  [nzOkLoading]="isOkLoading"
>
  <div *nzModalContent>
    <form nz-form [formGroup]="validateForm">
      <nz-form-item>
        <nz-form-label [nzSm]="6" [nzXs]="24" nzRequired nzFor="name">名称</nz-form-label>
        <nz-form-control [nzSm]="14" [nzXs]="24" nzErrorTip="The input is not valid name!">
          <!-- [ngModel]="name"和this.validateForm.setValue不可以同时使用，一起使用时ngModel才会生效, 使用ngModel如果跟弹窗使用关闭弹窗时不会制动清空数据 -->
          <input nz-input formControlName="name" id="name" />
        </nz-form-control>
      </nz-form-item>
      <nz-form-item>
        <nz-form-label [nzSm]="6" [nzXs]="24" nzFor="status">状态</nz-form-label>
        <nz-form-control [nzSm]="14" [nzXs]="24" nzErrorTip="The input is not valid status!">
          <nz-switch formControlName="status" id="status" [ngModel]="true" nzCheckedChildren="启用" nzUnCheckedChildren="禁用"></nz-switch>
        </nz-form-control>
      </nz-form-item>
      <nz-form-item>
        <nz-form-label [nzSm]="6" [nzXs]="24" nzFor="note">备注</nz-form-label>
        <nz-form-control [nzSm]="14" [nzXs]="24">
          <textarea rows="4" nz-input formControlName="note" id="note"></textarea> 
        </nz-form-control>
      </nz-form-item>
    </form>
  </div>
  
</nz-modal>
